package cn.common.dto;

/**
 * Copyright
 *
 * @Author WuHuang
 * @Date 2022/12/21
 */

public class RetryRequestParamDTO<T> extends RetryBaseRequest {
    private T requestBody;

    public RetryRequestParamDTO(final T requestBody) {
        this.requestBody = requestBody;
    }

    public RetryRequestParamDTO() {
    }

    public T getRequestBody() {
        return this.requestBody;
    }

    public void setRequestBody(final T requestBody) {
        this.requestBody = requestBody;
    }

    public boolean equals(final Object o) {
        if (o == this) {
            return true;
        } else if (!(o instanceof RetryRequestParamDTO)) {
            return false;
        } else {
            RetryRequestParamDTO<?> other = (RetryRequestParamDTO)o;
            if (!other.canEqual(this)) {
                return false;
            } else {
                Object this$requestBody = this.getRequestBody();
                Object other$requestBody = other.getRequestBody();
                if (this$requestBody == null) {
                    if (other$requestBody != null) {
                        return false;
                    }
                } else if (!this$requestBody.equals(other$requestBody)) {
                    return false;
                }

                return true;
            }
        }
    }

    protected boolean canEqual(final Object other) {
        return other instanceof RetryRequestParamDTO;
    }

    public int hashCode() {
        int result = 1;
        Object $requestBody = this.getRequestBody();
        result = result * 59 + ($requestBody == null ? 43 : $requestBody.hashCode());
        return result;
    }

    public String toString() {
        return "RetryRequestParamDTO(requestBody=" + this.getRequestBody() + ")";
    }
}

